package com.cloudkinto.entity;

import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import java.util.Date;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableLogic;
import com.baomidou.mybatisplus.annotation.TableField;
import java.io.Serializable;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

/**
 * <p>
 * 
 * </p>
 * @author ding
 * @since 2021-02-24
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName("t_consumables")
public class ConsumablesDo extends Model<ConsumablesDo> {

    private static final long serialVersionUID=1L;

    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    @TableField("order_id")
    private Long orderId;

    @TableField("name")
    private String name;

    @TableField("code")
    private String code;

    @TableField("length")
    private Float length;

    @TableField("width")
    private Float width;

    @TableField("height")
    private Float height;

    @TableField("weight")
    private Float weight;

    /**
     * 材料销售价
     */
    @TableField("sale_price")
    private Integer salePrice;

    /**
     * 材料成本价
     */
    @TableField("cost_price")
    private Integer costPrice;

    /**
     * 数量
     */
    @TableField("count")
    private Integer count;

    /**
     * 一件代发0   非拼车1
     */
    @TableField("type")
    private Integer type;

    @TableField("create_by")
    private Long createBy;

    @TableField("create_time")
    private Date createTime;

    @TableField("update_by")
    private Long updateBy;

    @TableField("update_time")
    private Date updateTime;

    @TableField("delete_by")
    private Long deleteBy;

    @TableField("delete_time")
    private Date deleteTime;

    @TableField("delete_flag")
    @TableLogic
    private Integer deleteFlag;


    @Override
    protected Serializable pkVal() {
        return this.id;
    }

}
